<template>
	<view class="report-container">
		<view class="title">
			<image src="/static/images/title.png" class="img" mode="scaleToFill" />
		</view>
		<view class="grade-box">
			<view class="grade">
				<!-- {{ zonghe_grade < 20 }} -->
				{{
					zonghe_grade?
					zonghe_grade < 20 ? 'A':
					zonghe_grade < 45  ? 'B':
					zonghe_grade < 80 ? 'C':
					zonghe_grade < 90 ? 'D':
					zonghe_grade <= 100 ? 'E': '':'C'
				}}
			</view>
			<view class="desc">你的评分</view>
		</view>

		<view class="report-section section01">
			<view class="title">评分解读</view>
			<view class="evaluate-box">
				<view class="tag">评估</view>
				<view class="time">{{update_time}}</view>
			</view>
			<view class="explain">
				<view class="text">评分解读:</view>
				<view class="box">
					<view class="item">
						<view class="grade">A</view>
						<view class="desc">优秀</view>
					</view>
					<view class="item">
						<view class="grade">B</view>
						<view class="desc">良好</view>
					</view>
					<view class="item">
						<view class="grade">C</view>
						<view class="desc">一般</view>
					</view>
					<view class="item">
						<view class="grade">D</view>
						<view class="desc">较差</view>
					</view>
					<view class="item">
						<view class="grade">E</view>
						<view class="desc">极差</view>
					</view>
				</view>
			</view>
			<view class="description">评分仅供参考，本报告包含身份校验、消费风险，失信等多个维度，是根据网络行为综合评估的，不包含个人隐私爬虫数据</view>
			<view class="tip-pic">
				<image v-if="sys_eq && zonghe_grade < 70" src="@//static/images/other/pass.png" class="img"></image>
				<image v-else src="@//static/images/other/tip-reject.png" class="img"></image>
			</view>
		</view>

		<view class="report-section section02">
			<view class="title">信息匹配</view>
			<view class="content">
				<view class="top">

					<image v-if="sys_eq" src="@/static/images/pp.png" class="img"></image>
					<image v-else src="@/static/images/bpp.png" class="img"></image>
					<view class="desc">身份证/姓名/手机号{{sys_eq?'匹配':'不匹配'}}</view>
				</view>
				<view class="bottom">
					<view class="line">
						<text class="desc">基本信息</text>
						<text class="info">{{name}}</text>
					</view>
					<view class="line">
						<text class="desc">身份证号</text>
						<text class="info">{{card_no}}</text>
					</view>
					<view class="line">
						<text class="desc">手机号</text>
						<text class="info">{{mobile}}</text>
					</view>
					<view class="line">
						<text class="desc">手机号码归属地</text>
						<text class="info">{{sys_province}}-{{sys_city}}</text>
					</view>
					<view class="line">
						<text class="desc">手机号码运营商</text>
						<text class="info">{{sys_attribute}}</text>
					</view>
					<view class="line">
						<text class="desc">黑名单逾期验证报告编号</text>
						<text class="info">{{orderNo}}</text>
					</view>
				</view>
			</view>
		</view>

		<view class="report-section section03">
			<view class="title">风险命中</view>
			<view class="content">
				<view class="risk">
					<view class="left">
						<view class="box">
							<view class="line">风险项</view>
							<view class="line">({{mzInfo.length}}项)</view>
						</view>

					</view>
					<view class="right">
						<view v-for=" (item,index) in mzInfo" class="line">{{index+1+'）'+item.name_rule}}</view>
					</view>
				</view>
				<view class="proposal">
					<view class="sub">建议</view>
					<view class="text">
						请保持良好的借贷习惯，切勿频繁申请，拒绝不明平台的审核邀请，不去注册申请新的网贷，按时还款已有的网贷，3-6个月会慢慢恢复分数。
					</view>
				</view>
			</view>
		</view>

		<view class="report-section section04">
			<view class="title">消费申请数据</view>
			<view class="content">
				<view id="echart01" style="width: 100%;height: 370rpx;">
				</view>
				<cc-advice content="减少申请机构频率，保持良好的借贷习惯。"></cc-advice>
			</view>
		</view>

		<view class="report-section section05">
			<view class="title">传统机构申请记录</view>
			<view class="content">
				<scroll-view class="top" scroll-x>
					<view class="box">
						<view class="item" v-for="(item,index) in ['7天','15天','1月','3月','6月','1年']"
							@click="xz00(index)">近{{ item }}</view>
					</view>
				</scroll-view>
				<view class="bottom">
					<cc-table :data="data00" />
					<view class="title"></view>
				</view>
			</view>
		</view>

		<view class="report-section section06">
			<view class="title">其它机构申请记录</view>
			<view class="content">
				<cc-table :data="data01" />
			</view>
		</view>

		<view class="report-section section07">
			<view class="title">贷款统计</view>
			<view class="content">
				<view class="top">
					<view class="block"></view>
					<view class="text">贷款统计</view>
				</view>
				<view class="bottom">
					<cc-table :data="data02" />

					<cc-table :data="data03" />
					<cc-table :data="data04" />
					<cc-table :data="data05" />
				</view>

			</view>
		</view>

		<view class="report-section section08">
			<view class="title">失信现状</view>
			<view class="content">
				<view class="top">
					<view class="block"></view>
					<view class="text">贷款统计</view>
				</view>
				<view class="bottom">
					<cc-table :data="data06" />
				</view>
			</view>
		</view>

		<view class="report-section section09">
			<view class="title">履约表现</view>
			<view class="content">
				<view class="content-item">
					<view class="top">
						<view class="text">履约表现</view>
					</view>
					<view class="bottom">
						<view class="bottom-item">
							<view class="left">消费总机构数</view>
							<view class="right">{{dataLybx[0]}}</view>
						</view>
						<view class="bottom-item">
							<view class="left">消费已结清机构数</view>
							<view class="right">{{dataLybx[1]}}</view>
						</view>
					</view>
				</view>
				<view class="content-item">
					<view class="top">
						<view class="text">履约现状</view>
					</view>
					<view class="bottom">
						<view class="bottom-item">
							<view class="left">当前是否履约失败</view>
							<view class="right">{{dataLybx[2]}}</view>
						</view>
						<view class="bottom-item">
							<view class="left">当前履约失败机构数</view>
							<view class="right">{{dataLybx[3]}}</view>
						</view>
					</view>
				</view>

				<view class="content-item">
					<view class="top">
						<view class="text">交互行为</view>
					</view>
					<view class="bottom">
						<view class="bottom-item">
							<view class="left">交互失败百分比</view>
							<view class="right">{{dataLybx[4]}}</view>
						</view>
						<view class="bottom-item">
							<view class="left">交互成功百分比</view>
							<view class="right">{{dataLybx[5]}}</view>
						</view>
					</view>
				</view>


				<view class="content-item">
					<view class="top">
						<view class="text">新增约定笔数（近半年）</view>
					</view>
					<view class="bottom">
						<view class="bottom-item">
							<view class="left">30天内新增消费次数统计</view>
							<view class="right">{{dataLybx[6]}}</view>
						</view>
						<view class="bottom-item">
							<view class="left">90天内新增消费次数统计</view>
							<view class="right">{{dataLybx[7]}}</view>
						</view>
						<view class="bottom-item">
							<view class="left">半年内新增消费次数统计</view>
							<view class="right">{{dataLybx[8]}}</view>
						</view>
					</view>
				</view>

				<view class="content-item" style="padding-bottom: 24rpx">
					<view class="top">
						<view class="text">贷款机构数</view>
					</view>
					<view class="bottom" style="margin-top: 24rpx">
						<view id="echart02" style="width: 100%;height: 252rpx;">
						</view>
					</view>
				</view>


				<view class="content-item">
					<view class="top">
						<view class="text">还款成功数</view>
					</view>
					<view class="bottom" style="margin-top: 24rpx">
						<view id="echart03" style="width: 100%;height: 320rpx;">
						</view>
					</view>
				</view>
			</view>
		</view>

		<view class="report-section section10">
			<view class="title">行为探针</view>
			<view class="content">
				<cc-table :data="data10" />
				<cc-table :data="data101" title="银行逾期欺诈风险" style="margin-top: 28rpx" />
				<cc-table :data="data102" title="网络欺诈失联风险" style="margin-top: 28rpx" />
			</view>
		</view>

		<view class="report-section section11">
			<view class="title">特殊名单验证</view>
			<view class="content">
				<view class="content-item">
					<view class="left">恶意投诉
					</view>
					<view>{{labels.indexOf('故意投诉行为')!=-1?'命中':'无'}}</view>
					<!-- <view class="right">未命中</view> -->
				</view>
				<view class="content-item">
					<view class="left">涉诈人员</view>
					<view>{{labels.indexOf('涉诈人员')!=-1?'命中':'无'}}</view>
				</view>
				<view class="content-item">
					<view class="left">羊毛党</view>
					<view>{{labels.indexOf('羊毛党')!=-1?'命中':'无'}}</view>
				</view>
			</view>
		</view>

		<view class="report-section section12">
			<view class="title">法院公告{{ detail1.civil.cases != undefined  ? '' : '（暂无）' }}</view>
			<view class="content">
				<view class="content-item">
					<!-- {{detail1.civil}} -->
					<view v-if="detail1.civil.cases != undefined" v-for="(item, index) in detail1.civil.cases"
						class="bottom">
						<view class="item">
							<view class="left">案号</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">案件类型</view>
							<view class="right">{{ item.n_ajlx }}</view>
						</view>
						<view class="item">
							<view class="left">法院</view>
							<view class="right">{{ item.n_jbfy }}</view>
						</view>
						<view class="item">
							<view class="left">诉讼身份</view>
							<view class="right">{{ item.n_ssdw }}</view>
						</view>
						<view class="item">
							<view class="left">立案时间</view>
							<view class="right">{{ item.d_larq  }}</view>
						</view>
						<view class="item">
							<view class="left">结案时间</view>
							<view class="right">{{ item.d_jarq}}</view>
						</view>
						<view class="item">
							<view class="left">结案方式</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">执行标的金额</view>
							<view class="right">{{ item.n_sqzxbdje}}</view>
						</view>
						<view class="item">
							<view class="left">判决结果</view>
							<view class="right">{{ item.n_jafs }}</view>
						</view>

						<view class="page">
							第{{index+1}}条 / 共{{detail1.civil.cases.length}}条
						</view>
					</view>
				</view>
			</view>
		</view>
		 
		<view class="report-section section12">
			<view class="title">涉案信息{{ detail1.criminal.cases != undefined  ? '' : '（暂无）' }}</view>
			<view class="content">
				<view class="content-item">
					<view v-if="detail1.criminal.cases != undefined " v-for="(item, index) in detail1.criminal.cases"
						class="bottom">
						<view class="item">
							<view class="left">案号</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">案件类型</view>
							<view class="right">{{ item.n_ajlx }}</view>
						</view>
						<view class="item">
							<view class="left">法院</view>
							<view class="right">{{ item.n_jbfy }}</view>
						</view>
						<view class="item">
							<view class="left">诉讼身份</view>
							<view class="right">{{ item.n_ssdw }}</view>
						</view>
						<view class="item">
							<view class="left">立案时间</view>
							<view class="right">{{ item.d_larq  }}</view>
						</view>
						<view class="item">
							<view class="left">结案时间</view>
							<view class="right">{{ item.d_jarq}}</view>
						</view>
						<view class="item">
							<view class="left">结案方式</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">执行标的金额</view>
							<view class="right">{{ item.n_sqzxbdje}}</view>
						</view>
						<view class="item">
							<view class="left">判决结果</view>
							<view class="right">{{ item.n_jafs }}</view>
						</view>

						<view class="page">
							第{{index+1}}条 / 共{{detail1.criminal.cases.length}}执行
						</view>
					</view>
				</view>
			</view>
		</view>

		<view class="report-section section12">
			<view class="title">案件流程{{ detail1.administrative.cases != undefined  ? '' : '（暂无）' }}</view>
			<view class="content">
				<view class="content-item">
					<view v-if="'cases' in detail1.administrative" v-for="(item, index) in detail1.administrative.cases"
						class="bottom">
						<view class="item">
							<view class="left">案号</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">案件类型</view>
							<view class="right">{{ item.n_ajlx }}</view>
						</view>
						<view class="item">
							<view class="left">法院</view>
							<view class="right">{{ item.n_jbfy }}</view>
						</view>
						<view class="item">
							<view class="left">诉讼身份</view>
							<view class="right">{{ item.n_ssdw }}</view>
						</view>
						<view class="item">
							<view class="left">立案时间</view>
							<view class="right">{{ item.d_larq  }}</view>
						</view>
						<view class="item">
							<view class="left">结案时间</view>
							<view class="right">{{ item.d_jarq}}</view>
						</view>
						<view class="item">
							<view class="left">结案方式</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">执行标的金额</view>
							<view class="right">{{ item.n_sqzxbdje}}</view>
						</view>
						<view class="item">
							<view class="left">判决结果</view>
							<view class="right">{{ item.n_jafs }}</view>
						</view>

						<view class="page">
							第{{index+1}}条 / 共{{detail1.administrative.cases.length}}执行
						</view>
					</view>
				</view>
			</view>
		</view>

		<view class="report-section section12">
			<view class="title">执行公告{{ detail1.implement.cases != undefined  ? '' : '（暂无）' }}</view>
			<view class="content">
				<view class="content-item">
					<view v-if="'cases' in detail1.implement" v-for="(item, index) in detail1.implement.cases"
						class="bottom">
						<view class="item">
							<view class="left">案号</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">案件类型</view>
							<view class="right">{{ item.n_ajlx }}</view>
						</view>
						<view class="item">
							<view class="left">法院</view>
							<view class="right">{{ item.n_jbfy }}</view>
						</view>
						<view class="item">
							<view class="left">诉讼身份</view>
							<view class="right">{{ item.n_ssdw }}</view>
						</view>
						<view class="item">
							<view class="left">立案时间</view>
							<view class="right">{{ item.d_larq  }}</view>
						</view>
						<view class="item">
							<view class="left">结案时间</view>
							<view class="right">{{ item.d_jarq}}</view>
						</view>
						<view class="item">
							<view class="left">结案方式</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">执行标的金额</view>
							<view class="right">{{ item.n_sqzxbdje}}</view>
						</view>
						<view class="item">
							<view class="left">判决结果</view>
							<view class="right">{{ item.n_jafs }}</view>
						</view>

						<view class="page">
							第{{index+1}}条 / 共{{detail1.implement.cases.length}}执行
						</view>
					</view>
				</view>
			</view>
		</view>

		<view class="report-section section12">
			<view class="title">限制高消费{{ detail1.bankrupt.cases != undefined  ? '' : '（暂无）' }}</view>
			<view class="content">
				<view class="content-item">
					<view v-if="'cases' in detail1.bankrupt" v-for="(item, index) in detail1.bankrupt .cases"
						class="bottom">
						<view class="item">
							<view class="left">案号</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">案件类型</view>
							<view class="right">{{ item.n_ajlx }}</view>
						</view>
						<view class="item">
							<view class="left">法院</view>
							<view class="right">{{ item.n_jbfy }}</view>
						</view>
						<view class="item">
							<view class="left">诉讼身份</view>
							<view class="right">{{ item.n_ssdw }}</view>
						</view>
						<view class="item">
							<view class="left">立案时间</view>
							<view class="right">{{ item.d_larq  }}</view>
							<view class="right">{{ item.d_larq  }}</view>

						</view>
						<view class="item">
							<view class="left">结案时间</view>
							<view class="right">{{ item.d_jarq}}</view>
						</view>
						<view class="item">
							<view class="left">结案方式</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">执行标的金额</view>
							<view class="right">{{ item.n_sqzxbdje}}</view>
						</view>
						<view class="item">
							<view class="left">判决结果</view>
							<view class="right">{{ item.n_jafs }}</view>
						</view>

						<view class="page">
							第{{index+1}}条 / 共{{detail1.bankrupt.cases.length}}执行
						</view>
					</view>
				</view>
			</view>
		</view>

		<view class="report-section section12">
			<view class="title">曝光台{{ detail1.preservation.cases != undefined  ? '' : '（暂无）' }}</view>
			<view class="content">
				<view class="content-item">
					<view v-if="'cases' in detail1.preservation" v-for="(item, index) in detail1.preservation.cases"
						class="bottom">
						<view class="item">
							<view class="left">案号</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">案件类型</view>
							<view class="right">{{ item.n_ajlx }}</view>
						</view>
						<view class="item">
							<view class="left">法院</view>
							<view class="right">{{ item.n_jbfy }}</view>
						</view>
						<view class="item">
							<view class="left">诉讼身份</view>
							<view class="right">{{ item.n_ssdw }}</view>
						</view>
						<view class="item">
							<view class="left">立案时间</view>
							<view class="right">{{ item.d_larq  }}</view>
						</view>
						<view class="item">
							<view class="left">结案时间</view>
							<view class="right">{{ item.d_jarq}}</view>
						</view>
						<view class="item">
							<view class="left">结案方式</view>
							<view class="right">{{ item.c_ah }}</view>
						</view>
						<view class="item">
							<view class="left">执行标的金额</view>
							<view class="right">{{ item.n_sqzxbdje}}</view>
						</view>
						<view class="item">
							<view class="left">判决结果</view>
							<view class="right">{{ item.n_jafs }}</view>
						</view>

						<view class="page">
							第{{index+1}}条 / 共{{detail1.preservation.cases.length}}执行
						</view>
					</view>
				</view>
			</view>
		</view>

		<cc-advice content="请立即履行生效法律文书确定的义务，向相关法院申请移出失信被执行人和法院被执行人名单。"></cc-advice>

		<view class="section13">
			<view class="section-item">
				<view class="text">提高信用评分消除风险的建议</view>
				<view class="content">
					<view class="line">
						<view class="left">1.</view>
						<view class="right">信用卡一年内申请不超过6次，含同一机构，网贷3个月内申请不超过20次，控制申请频率；</view>
					</view>
					<view class="line">
						<view class="left">2.</view>
						<view class="right">如有逾期或被执行等不良记录，保持信用良好1-2年，记录可以滚动覆盖过去。</view>
					</view>

					<view class="line">
						<view class="left">3.</view>
						<view class="right">保持良好的接待习惯，切勿频繁申请，拒绝不明平台的审核邀请；。</view>
					</view>
					<view class="line">
						<view class="left">4.</view>
						<view class="right">减少和网贷黑名单的这类人群的联系，提高自己朋友圈优良信用人群比例</view>
					</view>
				</view>
			</view>

			<view class="section-item">
				<view class="text">大数据报告说明</view>
				<view class="content">
					报告本人授权查询，本报告包含身份校验，借贷风险、失信等多个维度。是根据网络行为综合评估的，不包含个人隐私爬虫数据。只做大数据信息的获取及分析，不对原始数据做任何修改，仅供参考使用。如果你对报告有异议，出于合作平台数据隐私的保护，平台不做任何解释。
				</view>
			</view>
		</view>

		<template v-if="orderNo">
			<liu-drag-button @clickBtn="FP()" :bottomPx="85">发票</liu-drag-button>
			<liu-drag-button @clickBtn="FX()">分享</liu-drag-button>
		</template>
	</view>

</template>
<script>
	import * as echarts from "echarts";
	import {
		query
	} from '@/api/jinjian.js'

	import {
		bdpTemInfo
	} from '@/utils/temInfo.js'

	import {
		data00,
		data01,
		data02,
		data03,
		data04,
		data05,
		data06,
		data10,
		data101,
		data102,
		ctjgsq,

		qtjgsq,
		dktjRow,
		sxxzRow,
		lybxRow,
		dataLybx,
		disEdata,
		e3data,
		xwtz10Row,
		disposeAls,
		yhyqqzfx,
		wlqzslfx,
		disposeEl
	} from '@/utils/poster.js'

	export default {
		data() {
			return {
				data00,
				data01,
				data02,
				data03,
				data04,
				data05,
				data06,
				data10,
				data101,
				data102,

				orderNo: '',
				update_time: '',
				zonghe_grade: '',
				sys_eq: false,
				name: '**小',
				card_no: '************103873',
				mobile: '*******8365',
				sys_province: '',
				sys_city: '',
				sys_attribute: '',
				mzInfo: [],
				yData: [0, 0, 0, 0, 0], //申请次数
				taskDate: [0, 0, 0, 0, 0], //申请机构
				ctjgsq: [
					[0, 0],
					[0, 0],
					[0, 0],
					[0, 0],
					[0, 0],
					[0, 0]
				],
				dkjgs: [10, 10, 10],
				dataLybx,
				// fysx: [],
				// fyxg: [],
				detail1: {
					civil: {},
					criminal: {},
					administrative: {},
					implement: {},
					bankrupt: {},
					preservation: {}
				},
				labels: []
			}
		},
		onLoad(options) {
			this.$modal.loading()
			if (options.orderNo) {
				this.orderNo = options.orderNo
				query({
					orderNo: this.orderNo,
					name: '1'
				}).then(res => {
					if (res.code === 200) {
						let data = res.data
						this.update_time = data.createTime
						this.name = data.name
						this.card_no = data.cardNo
						this.mobile = data.mobile
						this.hanbleData(JSON.parse(data.queryInfo))
						this.$modal.closeLoading()
					} else {
						this.$modal.msg(res.msg)
					}
				})
			} else {
				this.$nextTick(() => {
					this.hanbleData(bdpTemInfo)
					this.$modal.closeLoading()
				})
			}
		},
		methods: {
			hanbleData(data) {
				
				console.log('---AllData---', data)
				
				if(data.labels &&  data.labels.retdata){
					this.labels = data.labels.retdata
				}
				let sjsys = data.sjsys
				console.log('---sjsys---', sjsys)
				if (sjsys.retcode == '000000') {
					const retdata = sjsys.retdata
					this.sys_province = retdata.province
					this.sys_city = retdata.city
					this.sys_attribute = retdata.attribute
					this.sys_eq = retdata.checkResult == '0'
				} else {
					this.$modal.msg(sjsys.retmsg)
				}
				let dttz = data.dttz
				console.log('---dttz---', dttz)
				if (dttz.retcode == '000000') {
					const retdata = dttz.retdata
					if (retdata.code == '00') {
						if (retdata.Flag.riskstrategy == '1') {


							this.zonghe_grade = parseInt(retdata.Rule.result.final_weight);

							console.log('--评分--', this.zonghe_grade)
						}
						if (retdata.Flag.ruleexecutionlimited == '1') {
							const r = retdata.Rule.hit_rules.ruleexecutionlimited
							for (const key in r) {
								this.mzInfo.push(r[key])
							}
						}
						if (retdata.Flag.rulespeciallist_c == '1') {
							const r = retdata.Rule.hit_rules.rulespeciallist_c
							for (const key in r) {
								this.mzInfo.push(r[key])
							}
						}
						if (retdata.Flag.ruleapplyloan == '1') {
							const r = retdata.Rule.hit_rules.ruleapplyloan
							for (const key in r) {
								this.mzInfo.push(r[key])
							}
						}
						if (retdata.Flag.specialList_c == '1') {
							// console.log('---specialList_c---', retdata.Flag.specialList_c)
						}
						if (retdata.Flag.applyloanstr == '1') {
							const als = disposeAls(retdata.ApplyLoanStr)
							this.yData = als.allnum
							this.taskDate = als.orgnum
							this.ctjgsq = ctjgsq(retdata.ApplyLoanStr)
							this.xz00(0)
							qtjgsq(retdata.ApplyLoanStr)
						}
						if (retdata.Flag.specialList_c == '1') {
							yhyqqzfx(retdata.SpecialList_c)
							wlqzslfx(retdata.SpecialList_c)
						}
						// if (retdata.Flag.executionlimited == '1') {
						// 	let el = disposeEl(retdata.ExecutionLimited)
						// 	this.fysx = el.fysx
						// 	this.fyxg = el.fyxg
						// }
					} else if (retdata.code == '100002') {
						// 查询成功，但策略配置里全部子产品均未匹配到结果
					} else {
						this.$modal.msg(dttz.retmsg)
					}
				} else {
					this.$modal.msg(dttz.retmsg)
				}
				this.initEchart01()
				let jxzs = data.jxzs.retdata
				dktjRow(jxzs)
				sxxzRow(jxzs)
				lybxRow(jxzs)
				this.dkjgs = [
					disEdata(jxzs.xyp_cpl0009),
					disEdata(jxzs.xyp_cpl0011),
					disEdata(jxzs.xyp_cpl0012)
				]
				this.initEchart02()
				e3data[0].value = disEdata(jxzs.xyp_cpl0019)
				e3data[1].value = disEdata(jxzs.xyp_cpl0019)
				e3data[2].value = disEdata(jxzs.xyp_cpl0019)
				e3data[3].value = disEdata(jxzs.xyp_cpl0019)
				this.initEchart03()
				xwtz10Row(jxzs)
				let grss = data.grss
				if (grss.retcode == '000000') {
					const retdata = grss.retdata
					if (retdata.resultCode == 1) {
						this.detail1 = retdata.detail[0]
					}
				}
			},

			xz00(index) {
				const item = this.ctjgsq[index]
				for (let i = 0; i < item.length; i++) {
					for (let j = 0; j < item[i].length; j++) {
						data00[i + 1][j + 1].value = item[i][j]
					}
				}
			},

			initEchart01() {
				var echart01 = echarts.init(document.getElementById("echart01"));
				const options = {
					title: {
						text: "消费申请走势",
						// top:"20rpx"
						textStyle: {
							fontWeight: "normal",
							color: "#001850",
							fontsize: "28rpx"
						}
					},
					tooltip: {
						trigger: 'axis', // 触发类型，可选 'item' 和 'axis'
						axisPointer: { // 坐标轴指示器配置
							type: 'shadow' // 默认为 'line'，可选 'line' | 'shadow'
						}
					},
					xAxis: {
						type: "category",
						data: ['15天', '1个月', '3个月', '6个月', '12个月'],
						axisLabel: {
							color: "#9AA5B5",
							fontSize: "24rpx"
						},
						axisTick: {
							show: false
						}
					},
					grid: {
						left: '10%', // 设置图表内容离左侧的距离
						right: '10%', // 设置图表内容离右侧的距离
						top: '80px', // 设置图表内容离顶部的距离（确保不与标题重叠）
						bottom: '10%' // 设置图表内容离底部的距离
					},
					legend: {
						data: ["申请次数", "申请机构数"],
						top: "32",
						left: "68",
						itemWidth: 6,
						itemHeight: 6,
						textStyle: {
							fontWeight: "normal",
							color: "#9AA5B5",
							fontsize: "24rpx"
						}
					},
					yAxis: {},
					series: [{
							type: "bar", //形状为柱状图
							data: this.yData,
							stack: "总申请数",
							name: "申请次数", // legend属性
							label: {
								// 柱状图上方文本标签，默认展示数值信息
								show: false,
								position: "top"
							},
							itemStyle: {
								color: "#62D7CC"
							},
							barWidth: 10
						},
						{
							type: "bar", //形状为柱状图
							data: this.taskDate,
							name: "申请机构数", // legend属性

							stack: "总申请数",
							label: {
								// 柱状图上方文本标签，默认展示数值信息
								show: false,
								position: "top"
							},
							itemStyle: {
								color: "#3170FF"
							},
							barWidth: 10
						}
					]
				}
				echart01.setOption(options)
				window.addEventListener("resize", () => {
					echart01.resize()
				})
			},

			initEchart02() {
				var echart02 = echarts.init(document.getElementById("echart02"));
				const options = {
					xAxis: {
						type: "category",
						data: ['7天', '30天', '90天'],
						axisLabel: {
							color: "#9AA5B5",
							fontSize: "24rpx"
						},
						axisTick: {
							show: false
						}
					},
					tooltip: {
						trigger: 'axis', // 触发类型，可选 'item' 和 'axis'
						axisPointer: { // 坐标轴指示器配置
							type: 'shadow' // 默认为 'line'，可选 'line' | 'shadow'
						}
					},
					grid: {
						left: '10%', // 设置图表内容离左侧的距离
						right: '10%', // 设置图表内容离右侧的距离
						top: '10%', // 设置图表内容离顶部的距离（确保不与标题重叠）
						bottom: '15%' // 设置图表内容离底部的距离
					},
					yAxis: {
						type: "value",
						interval: 5,
						splitLine: {
							show: false
						},
						axisLabel: {
							color: "#9AA5B5",
							fontSize: "24rpx"
						},
					},
					series: [{
						type: "bar", //形状为柱状图
						data: this.dkjgs,
						name: "申请机构数", // legend属性

						stack: "总申请数",
						label: {
							// 柱状图上方文本标签，默认展示数值信息
							show: false,
							position: "top"
						},
						itemStyle: {
							color: "#3170FF"
						},
						barWidth: 20
					}]
				}
				echart02.setOption(options)
				window.addEventListener("resize", () => {
					echart02.resize()
				})

			},

			initEchart03() {
				let sum = e3data.reduce((acc, item) => {
					return acc + item.value
				}, 0)
				var echart03 = echarts.init(document.getElementById("echart03"))
				const options = {
					color: ['#3B6FF6', '#77CEF0', '#5B3BF6', '#77DEA4'], // 颜色数组，按顺序应用
					grid: {
						top: '10%', // 设置图表内容离顶部的距离（确保不与标题重叠）
						bottom: '15%' // 设置图表内容离底部的距离
					},
					legend: {
						// data:["申请次数","申请机构数"],
						top: "50",
						// left:"68",
						orient: 'horizontal',
						left: 'right',
						itemGap: 20,
						width: "50%",
						itemWidth: 6,
						itemHeight: 6,
						textStyle: {
							fontWeight: "normal",
							color: "#9AA5B5",
							fontsize: "24rpx"
						},
						formatter: function(name) {
							var find = e3data.find(item => item.name === name);
							if (find) {
								return `${name}: ${find.value} 笔`
							}
							return `${name}`
						}
					},
					tooltip: {
						trigger: "item",
						formatter: function(params) {
							// return `Series: ${params.name}<br/>Category: ${params.value}<br/>Value: ${params.value}`;
							let rate = ((params.value / sum) * 100).toFixed(2) + "%"
							return rate
						}
					},
					series: [{
						name: '访问来源',
						type: 'pie',
						roseType: 'area',
						radius: ['50%', '90%'], // 设置内外半径，实现环形
						center: ['20%', '50%'],
						avoidLabelOverlap: false,
						label: {
							show: false, // 隐藏标签
							position: 'center'
						},
						emphasis: {
							label: {
								show: true,
								fontSize: '30',
								fontWeight: 'bold'
							}
						},
						labelLine: {
							show: false
						},
						data: e3data
					}],
					graphic: {
						type: 'text',
						left: '10%',
						top: '40%',
						style: {
							text: "", // 设置显示的文字内容
							textAlign: 'center',
							fill: '#000', // 字体颜色
							fontSize: 14, // 字体大小
							fontWeight: 'bold'
						}
					}
				}
				echart03.setOption(options)
				window.addEventListener("resize", () => {
					echart03.resize()
				})
			}
		}
	}
</script>
<style scoped lang="scss">
	@import "../static/scss/poster.scss";
</style>